POST Outstream Player
Overview
The following table contains important information about the POST method for creating an outstream player.
| POST Outstream Player | |
|---|---|
| Method | POST |
| URL or Endpoint | /api/v1/projects/projectId/outstream-players |
| Headers | Authorization |
| Parameters | projectId |
| Body | Check request body below |
The description of the URL parameter is as follows:
| projectId URL Parameter | |
|---|---|
| URL Parameter Name | projectId |
| Mandatory | Yes |
| Type | string |
| Description | Unique Id of the project |
Request Body
{
"name": "string",
"responsive": true,
"width": 0,
"height": 0,
"releaseChannelId": 0,
"muteOnStart": true,
"viewableThresholdPercentage": 0,
"autoStartOnViewableOn": true,
"autoPauseOnViewableOn": true,
"volumeSlider": true,
"playButton": true,
"muteButton": true,
"controlBarIconsDefaultColor": "string",
"controlBarIconsHoverColor": "string",
"controlBarSliderProgressColor": "string",
"controlBarSliderRailColor": "string",
"controlBarSliderDraggerColor": "string"
}
Information about the fields that appear when you type in the request body are displayed in the table below.
| Field Name | Type | Mandatory | Description |
|---|---|---|---|
| name | string | Yes | The name of the outstream player. |
| responsive | boolean | Conditional | If set to true, the player size will be responsive. In this case, width and height are not mandatory. If false, then width and height are required. |
| width | integer | Conditional | The width of the player in pixels. This field is mandatory if responsive is false. |
| height | integer | Conditional | The height of the player in pixels. This field is mandatory if responsive is false. |
| releaseChannelId | integer | Yes | The ID of the release channel used for the player version. |
| muteOnStart | boolean | Yes | If true, the player will start muted. |
| viewableThresholdPercentage | integer | Yes | The percentage of player viewability required to trigger viewable events. |
| autoStartOnViewableOn | boolean | Yes | If true, the player will automatically start when it becomes viewable. |
| autoPauseOnViewableOn | boolean | Yes | If true, the player will automatically pause when it is no longer viewable. |
| volumeSlider | boolean | Yes | Whether to display the volume slider control. |
| playButton | boolean | Yes | Whether to display the play button control. |
| muteButton | boolean | Yes | Whether to display the mute button control. |
| controlBarIconsDefaultColor | string | No | Color for control bar icons in default state. |
| controlBarIconsHoverColor | string | No | Color for control bar icons on hover. |
| controlBarSliderProgressColor | string | No | Color of the progress part of the control bar slider. |
| controlBarSliderRailColor | string | No | Color of the rail (background) of the control bar slider. |
| controlBarSliderDraggerColor | string | No | Color of the dragger (handle) on the control bar slider. |
Response
{
"publicId": "string",
"name": "string",
"responsive": true,
"width": 0,
"height": 0,
"releaseChannelId": 0,
"muteOnStart": true,
"viewableThresholdPercentage": 0,
"autoStartOnViewableOn": true,
"autoPauseOnViewableOn": true,
"volumeSlider": true,
"playButton": true,
"muteButton": true,
"controlBarIconsDefaultColor": "string",
"controlBarIconsHoverColor": "string",
"controlBarSliderProgressColor": "string",
"controlBarSliderRailColor": "string",
"controlBarSliderDraggerColor": "string",
"orderNumber": 0,
"releaseChannel": {
"id": 0,
"name": "string",
"originalPath": "string",
"templateOriginalPath": "string"
}
}
Information about the fields that appear when you receive the response are displayed in the table below.
| Field Name | Type | Description |
|---|---|---|
| publicId | string | Public ID of the outstream player. |
| name | string | Name of the outstream player. |
| responsive | boolean | Specifies if the player layout is responsive. |
| width | integer | Width of the player in pixels (used when responsive is false). |
| height | integer | Height of the player in pixels (used when responsive is false). |
| releaseChannelId | integer | The ID of the release channel used for the player version. |
| muteOnStart | boolean | If true, the player starts muted. |
| viewableThresholdPercentage | integer | The percentage of player viewability required to trigger viewable events. |
| autoStartOnViewableOn | boolean | If true, the player will automatically start when it becomes viewable. |
| autoPauseOnViewableOn | boolean | If true, the player will automatically pause when it is no longer viewable. |
| volumeSlider | boolean | Whether to display the volume slider control. |
| playButton | boolean | Whether to display the play button control. |
| muteButton | boolean | Whether to display the mute button control. |
| controlBarIconsDefaultColor | string | Color for control bar icons in default state. |
| controlBarIconsHoverColor | string | Color for control bar icons on hover. |
| controlBarSliderProgressColor | string | Color of the progress part of the control bar slider. |
| controlBarSliderRailColor | string | Color of the rail (background) of the control bar slider. |
| controlBarSliderDraggerColor | string | Color of the dragger (handle) on the control bar slider. |
If the action is successful, the service sends back an HTTP 200 or 201 response.
Errors
For information about the errors that are common to all actions, see Common Errors:
HTTP Status Code 400: Bad Request
HTTP Status Code 401: Unauthorized
HTTP Status Code 403: Forbidden
HTTP Status Code 404: Result Not Found
HTTP Status Code 500: Internal Server Error
HTTP Status Code 503: Backend Fetch Failed